package com.ai.manager.edu.cms.info.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Component;

import com.ai.dao.edu.cms.info.InfoPublishObjectMapper;
import com.ai.manager.edu.cms.info.InfoPublishObjectManager;
import com.ai.model.edu.cms.info.InfoPublishObject;
import com.ai.model.edu.cms.info.vo.InfoPublishObjectVO;

@Component("infoPublishObjectManager")
public class InfoPublishObjectManagerImpl implements InfoPublishObjectManager {
    @Resource
    private InfoPublishObjectMapper infoPublishObjectMapper;


    /**
     * 根据主键查询记录
     */
    public List<InfoPublishObjectVO> findInfoPublishObjectByAppId(Long id) {
    	return infoPublishObjectMapper.findInfoPublishObjectByAppId(id);
    }
    
    /**
     * 根据主键ID集合查询记录
     */
    public List<InfoPublishObjectVO> findInfoPublishObjectByAppIds(List<Long> ids) {
    	return infoPublishObjectMapper.findInfoPublishObjectByAppIds(ids);
    }

	/* 
	 * 批量新增object
	 */
	@Override
	public void batchAddInfoPublishObejct(List<InfoPublishObject> list) {
		infoPublishObjectMapper.batchAddInfoPublishObejct(list);
	}

	/* 
	 * 根据发布申请 批量删除object
	 */
	@Override
	public void delInfoPublishObjectsByPublishId(Long publishId) {
		infoPublishObjectMapper.delInfoPublishObjectsByPublishId(publishId);
	}

}